package com.yf1706.bean;

import java.io.Serializable;
import javax.persistence.*;

import com.alibaba.fastjson.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonIgnore;


/**
 * The persistent class for the emp_family_info database table.
 * 
 */
@Entity
@Table(name="emp_family_info")
@NamedQuery(name="EmpFamilyInfo.findAll", query="SELECT e FROM EmpFamilyInfo e")
public class EmpFamilyInfo implements Serializable {
	private static final long serialVersionUID = 1L;

	@Id
	@GeneratedValue(strategy=GenerationType.IDENTITY)
	private int id;

	private String address;

	private String email;

	private String fax;

	private String name;
	
	@ManyToOne
	@JoinColumn(name="relationship_id")
	private RelationshipSetting relationshipSetting;

	private String remark;

	private String tel;

	//bi-directional one-to-one association to Emp
	@OneToOne
	@JSONField(serialize = false)
	@JoinColumn(name="emp_id")
	private Emp emp;

	public EmpFamilyInfo() {
	}


	public EmpFamilyInfo(String address, String email, String fax, String name,
			RelationshipSetting relationshipSetting, String remark, String tel) {
		super();
		this.address = address;
		this.email = email;
		this.fax = fax;
		this.name = name;
		this.relationshipSetting = relationshipSetting;
		this.remark = remark;
		this.tel = tel;
	}


	public int getId() {
		return id;
	}


	public void setId(int id) {
		this.id = id;
	}


	public String getAddress() {
		return this.address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	public String getEmail() {
		return this.email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	public String getFax() {
		return this.fax;
	}

	public void setFax(String fax) {
		this.fax = fax;
	}

	public String getName() {
		return this.name;
	}

	public void setName(String name) {
		this.name = name;
	}


	public RelationshipSetting getRelationshipSetting() {
		return relationshipSetting;
	}


	public void setRelationshipSetting(RelationshipSetting relationshipSetting) {
		this.relationshipSetting = relationshipSetting;
	}


	public String getRemark() {
		return this.remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}

	public String getTel() {
		return this.tel;
	}

	public void setTel(String tel) {
		this.tel = tel;
	}

	public Emp getEmp() {
		return this.emp;
	}

	public void setEmp(Emp emp) {
		this.emp = emp;
	}

}